package tlias.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import tlias.dto.LogVO;
import tlias.pojo.*;
import tlias.service.LogService;

@Slf4j
@RestController
@RequestMapping("/log")
public class LogController {
    @Autowired
    private LogService logService;

    // 5.5 日志列表查询
    @GetMapping("/page")
    public Result page(PageQueryParam param) {
        log.info("日志分页查询，参数：{}", param);
        PageResult<LogVO> result = logService.page(param);
        return Result.success(result);
    }
}